package com.starry.JavaEEStudy;

import javax.servlet.*;
import javax.servlet.http.*;
import java.io.IOException;

public class ContextServlet4 extends HttpServlet {
    @Override
    protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
        System.out.println("我是Context4,servletContext中 key1的值是" + getServletContext().getAttribute("key1"));
    }

    @Override
    protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {

    }
}
